//
//  GKZYSelectionView.m
//  GKZYAid
//
//  Created by lanou3g on 16/2/27.
//  Copyright © 2016年 GKZYAid. All rights reserved.
//

#import "GKZYSelectionView.h"

@implementation GKZYSelectionView

- (instancetype)initWithFrame:(CGRect)frame
{
    if (self = [super initWithFrame:frame]) {
        
        [self addViews];
    }
    
    return self;
}

- (void)addViews{
    
    self.tableView = [[UITableView alloc] initWithFrame:[UIScreen mainScreen].bounds style:UITableViewStyleGrouped];
    [self addSubview:self.tableView];
    
    NSArray *array = @[@"a1.jpg",@"a2.jpg",@"a3.jpg",@"a4.jpg",@"a5.jpg"];
    SDCycleScrollView *cycleScrollView = [SDCycleScrollView cycleScrollViewWithFrame:CGRectMake(0, 0,self.frame.size.width, self.frame.size.height * 0.3) imageNamesGroup:array];
    cycleScrollView.autoScrollTimeInterval = 1.5;
    
    self.tableView.tableHeaderView = cycleScrollView;
    
}

/*
 // Only override drawRect: if you perform custom drawing.
 // An empty implementation adversely affects performance during animation.
 - (void)drawRect:(CGRect)rect {
 // Drawing code
 }
 */

@end
